package cn.gd.service.systemAdministration.sysLog;

import cn.gd.mapper.logging.SysLogMapper;
import cn.gd.pojo.SysLog;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SysLogServiceImpl implements SysLogService{
    @Autowired
    private SysLogMapper sysLogMapper;


    @Override
    public PageInfo<SysLog> querySysLogList(Integer pageNum, Integer pageSize, String userName, String... dateRange) {
        PageHelper.startPage(pageNum, pageSize);
        List<SysLog> sysLogList = sysLogMapper.getSysLogList(userName, dateRange);
        return new PageInfo<>(sysLogList);
    }
}
